﻿using System;
using System.Text;
using System.Collections.Generic;

using GotLyrics;
using GotLyrics.LyricGrabbers;
using System.Diagnostics;

using NUnit.Framework;

namespace GotLyrics.UnitTest
{
    /// <summary>
    /// Summary description for LyrDBGrabberTest
    /// </summary>
    [TestFixture]
    public class GrabberTests
    {
        [Test]
        public void LyricWikiGrabberTest()
        {
            LyricWikiGrabber grabber = new LyricWikiGrabber();
            TestGrabber(grabber);
        }

        [Test]
        public void LyrDBGrabberTest()
        {
            LyrDBGrabber grabber = new LyrDBGrabber();
            TestGrabber(grabber);
        }

        [Test]
        public void LyricsPluginGrabberTest()
        {
            LyricsPluginGrabber grabber = new LyricsPluginGrabber();
            TestGrabber(grabber);
        }

        [Test]
        public void WowLyricsGrabberTest()
        {
            WowLyricsGrabber grabber = new WowLyricsGrabber();
            TestGrabber(grabber);
        }

        [Test]
        public void LeosLyricsGrabberTest()
        {
            LeosLyricsGrabber grabber = new LeosLyricsGrabber();
            TestGrabber(grabber);
        }

        private void TestGrabber(ILyricGrabber grabber)
        {
            string lyrics = grabber.Execute(TestCommon.Context);
            
            Assert.IsFalse(string.IsNullOrEmpty(lyrics));

            Debug.WriteLine(lyrics);
        }
    }
}
